package me.yuxiaoyao.lock.annotation;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * @author kerryzhang on 2020/12/21
 */


@Retention(RetentionPolicy.RUNTIME)
@Target(value = {ElementType.METHOD})
public @interface DistributedLock {
    /**
     * SpEL 表达式KEY
     *
     * @return
     */
    String value();

    boolean block() default true;

    long timeout() default -1L;

    String lockExecutor() default "";

    String keyGenerator() default "";

}
